package com.jeeplus.test.jlnu.xlsxManage.domain.query;

import com.jeeplus.test.jlnu.xlsxManage.domain.entity.JlnuXlsxManage;
import lombok.Data;
import org.springframework.beans.BeanUtils;

import java.io.Serializable;

@Data
public class XlsxManageQuery implements Serializable {

    private Integer id;

    /**
     * 所属部门id
     **/
    private String officeId;

    /**
     * 类型
     **/
    private String type;

    /**
     * 名称
     **/
    private String name;

    /**
     * 内容
     **/
    private String content;

    /**
     *
     **/
    private String operatorId;

    private String userType;

    public JlnuXlsxManage makeCreateEntity() {
        JlnuXlsxManage XlsxManage = new JlnuXlsxManage();
        BeanUtils.copyProperties(this, XlsxManage);
        XlsxManage.setCreateById(operatorId);
        return XlsxManage;
    }

    public JlnuXlsxManage makeUpdateEntity(JlnuXlsxManage XlsxManage) {
        BeanUtils.copyProperties(this, XlsxManage);
        XlsxManage.setUpdateById(this.getOperatorId());
        return XlsxManage;
    }

}
